<include file="Public:header" />
<include file="Public:leftside" />
<div class="main-content">
	<div class="breadcrumbs breadcrumbs-fixed" id="breadcrumbs">
		<ul class="breadcrumb">
			<li> <i class="icon-home home-icon"></i> <a href="/">首页</a></li>
			<li class="active">栏目管理</li>
		</ul>
	</div>
	<div class="row panel-body" style="padding: 10px 0 0 32px;">
		<a href="/system/menuAdd/" class="btn btn-sm btn-primary">添加栏目</a>
	
	</div>
	<form class="well form-search" id="mainform" action="{:U('system/menu')}" method="post" style="width: 97.7%;margin: 8px auto;">
			<select id="navcid_select" name="cid">
				<option value="0" <eq name="type" value="0">selected</eq>>后台</option>
       			 <option value="1" <eq name="type" value="1">selected</eq>>城市合伙人</option>
                <option value="2" <eq name="type" value="2">selected</eq>>店铺管理</option>		
			</select>
		</form>
	<div class="page-content">
		<table id="sample-table-1" class="table table-striped table-bordered table-hover">
			<thead>
				<tr>
					<th class="center">ID</th>
					<th>栏目名</th>
					<th>模块地址</th>
					<th class="hidden-480">默认方法</th>
					
					<th>排序</th>
					<th>操作</th>
				</tr>
			</thead>
			<tbody>
				<volist name="menuArrayFlag" id="row">
					<tr>
						<td><?=$row['id']?></td>
						<td style="font-weight:bold;">
							<?=$row['name']?>
							<a href="javascript:void(0);" class="showChildrenMenu" menuCheck='0' menudatashow="<?=$row['id']?>">+</a>
						</td> 
						<td><?=$row['module']?></td>
						<td><?=$row['action']?></td>
						<td><?=$row['sort']?></td>
						<td>
							<div class="visible-md visible-lg hidden-sm hidden-xs btn-group">
								<button onClick="location.href='/system/menuAdd/tid/<?=$row['id']?>'" class="btn btn-xs btn-primary"> 添加子菜单 </button>
								<button onClick="location.href='/system/menuAdd/id/<?=$row['id']?>'" class="btn btn-xs btn-info"> <i class="icon-edit bigger-120"></i>编辑 </button>
								<if condition="$row.ishidden eq 0">
								<button onClick="location.href='/system/menuDelete/id/{$row.id}/ishidden/1'" class="btn btn-xs btn-danger"> <i class="icon-trash bigger-120"></i>隐藏 </button>
								<else />
								<button onClick="location.href='/system/menuDelete/id/{$row.id}/ishidden/0'" class="btn btn-xs btn-success"> <i class="icon-ok bigger-120"></i> 显示</button>
								</if>
								
							</div>
						</td>
					</tr>
				</volist>
			</tbody>
		</table>
	</div>
</div>
<script>
	$(function() {

			$("#navcid_select").change(function() {
				$("#mainform").submit();
			});

		});
	
</script>
<include file="Public:footer" />